<!DOCTYPE html>
<html>
    <head>
        <meta charset="UTF-8">
        <title>{:COMPANY} 系统管理后台</title>
        <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no" />
        <meta name="apple-mobile-web-app-capable" content="yes" />
        <meta name="description" content="">
        <meta name="keywords" content="coco bootstrap template, coco admin, bootstrap,admin template, bootstrap admin,">
        <meta name="author" content="Huban Creative">
        <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
        <!-- Base Css Files -->
        <link href="{:__BOOTSTRAP__}css/bootstrap.min.css" rel="stylesheet" />
        <link href="{:__CSS__}font-awesome/css/font-awesome.min.css" rel="stylesheet" />
        <link href="{:__CSS__}fontello/css/fontello.css" rel="stylesheet" />

        <!-- Extra CSS Libraries Start -->
        <link href="{:__CSS__}style.css" rel="stylesheet" type="text/css" />
        <!-- Extra CSS Libraries End -->

        <!-- HTML5 Shim and Respond.js IE8 support of HTML5 elements and media queries -->
        <!-- WARNING: Respond.js doesn't work if you view the page via file:// -->
        <!--[if lt IE 9]>
                <script src="https://oss.maxcdn.com/libs/html5shiv/3.7.0/html5shiv.js"></script>
                <script src="https://oss.maxcdn.com/libs/respond.js/1.3.0/respond.min.js"></script>
                <![endif]-->

        <link rel="shortcut icon" href="{:__IMG__}Besiness/favicon.ico" />

    </head>
    <body>
        <div class="login_bk">
            <div class="login_box">
                <p>系统管理平台</p>
                <form method="post" action="{:U('Public/login')}">
                    <div class="login">
                        <div class="lg_input">
                            <label>账号</label>
                            <input type="text" name="username" placeholder="请输入账号"/>
                        </div>
                        <div class="lg_img">
                            <span>......</span><img src="{:__IMG__}Besiness/my.png"><span>......</span>
                        </div>
                        <div class="lg_input">
                            <label>密码</label>
                            <input type="password" name="password" placeholder="请输入密码"  />
                        </div>
                        <div class="clear"></div>
                        <div class="lg_login">
                            <input type="text" placeholder="输入验证" name="code"  />
                            <img class="lg_yan" style='width:100px;height: 40px' src="{:U('Admin/Public/verify')}">
                            <button class="btn-success" type="submit" >登录</button>
                        </div>
                    </div>
                </form>
            </div>
            <div class="footer">Copyright © 2016 {:COMPANY}</div>
        </div>
        <script type="text/javascript" src="{:__LIBS__}jquery/jquery-1.11.1.min.js"></script> 
        <script type="text/javascript" src="{:__JS__}common.js" ></script>
        <script>
            $(function () {
                var dH = $(document).height();
                var wH = $(".login_box").height() / 2;
                $(".login_bk").height(dH);
                $(".login_box").css("padding-top", dH / 2 - wH);
                $("input").focus(function () {
                    $(this).parent(".lg_input").css({
                        "background": "#505A60"
                    });
                });
                $("input").blur(function () {
                    $(this).parent(".lg_input").css({
                        "background": "#758F9D"
                    });
                });
                $(".lg_yan").bind("click", function () {
                    var obj = $(this);
                    var num = getRandom(9);
                    obj.attr("src", "/Admin/Public/verify.html?" + num + "")

                });
                function getRandom(n) {
                    return Math.floor(Math.random() * n + 1);
                }
            });
        </script>
    </body>
</html>
